#ifndef _BUOLA_GUI_COCOA_AUTO_FUNCTIONS_H_
#define _BUOLA_GUI_COCOA_AUTO_FUNCTIONS_H_

namespace buola { namespace gui { namespace cocoa {

class CCocoaToolkit;
class CCocoaExposeHelper;
CCocoaToolkit *get_cocoa_toolkit();

inline CRect_d nsrect_to_crect_d(NSRect pRect)
{
    return CRect_d(CPoint_d(pRect.origin.x,pRect.origin.y),CSize_d(pRect.size.width,pRect.size.height));
}

inline CPoint_d nspoint_to_point_d(NSPoint pPoint)
{
    return CPoint_d(pPoint.x,pPoint.y);
}

inline std::string nsstring_to_string(NSString *pString)
{
    return std::string([pString UTF8String]);
}

inline std::wstring nsstring_to_wstring(NSString *pString)
{
    return utf32([pString UTF8String]);
}

/*namespace cocoa*/ } /*namespace gui*/ } /*namespace buola*/ }

#endif
